package com.irs.service.impl;

import java.util.List;

import com.tuosha.dao.UsersDao;
import com.tuosha.model.UsersEntity;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import com.irs.mapper.MainMapper;
import com.irs.mapper.TbUsersMapper;
import com.irs.pojo.TbUsers;
import com.irs.pojo.TbUsersExample;
import com.irs.pojo.TbUsersExample.Criteria;
import com.irs.service.MainService;
@Service
public class MainServiceImpl implements MainService {

	@Autowired
	private UsersDao usersDao;

	@Autowired
	private MainMapper mainMapper;

	@Override
	public List<UsersEntity> selUserList() {
		UsersEntity example=new UsersEntity();

		return usersDao.queryList(example);
	}

	@Override
	public List<UsersEntity> selUsersToday() {
		return mainMapper.selUsersToday();
	}

	@Override
	public List<UsersEntity> selUsersYestoday() {
		return mainMapper.selUsersYesterday();
	}


	@Override
	public List<UsersEntity> selUsersYearWeek() {
		// TODO Auto-generated method stub
		return mainMapper.selUsersYearWeek();
	}

	@Override
	public List<UsersEntity> selUsersMonth() {
		// TODO Auto-generated method stub
		return mainMapper.selUsersMonth();
	}

	@Override
	public int seUserCountBygender(int i) {
		// TODO Auto-generated method stub
		UsersEntity example=new UsersEntity();

		List<UsersEntity> list = usersDao.queryList(example);
		return list.size();
	}

}
